from mako import runtime, filters, cache
UNDEFINED = runtime.UNDEFINED
_magic_number = 2
_modified_time = 1212609402.19662
_template_filename='/home/andi/devel/python/pylons/votafam-ng/votafam/votafam/templates/admin/cad_votacao.mako'
_template_uri='/admin/cad_votacao.mako'
_template_cache=cache.Cache(__name__, _modified_time)
_source_encoding='utf-8'
_exports = ['include_local_javascript', 'include_local_styles']


def _mako_get_namespace(context, name):
    try:
        return context.namespaces[(__name__, name)]
    except KeyError:
        _mako_generate_namespaces(context)
        return context.namespaces[(__name__, name)]
def _mako_generate_namespaces(context):
    pass
def _mako_inherit(template, context):
    _mako_generate_namespaces(context)
    return runtime._inherit_from(context, '/admin.mako', _template_uri)
def render_body(context,**pageargs):
    context.caller_stack.push_frame()
    try:
        __M_locals = dict(pageargs=pageargs)
        h = context.get('h', UNDEFINED)
        c = context.get('c', UNDEFINED)
        # SOURCE LINE 2
        context.write(u'\n')
        # SOURCE LINE 5
        context.write(u'\n')
        # SOURCE LINE 25
        context.write(u'\n\n<p style="text-align: center"><span class="destak">Cadastro de Vota&ccedil;&otilde;es</span></p>\n')
        # SOURCE LINE 28
        context.write(unicode(h.form(h.url(action='save',id=c.form_result['cdvotacao']),method='post',id_='votacao_form')))
        context.write(u'\n')
        # SOURCE LINE 29
        context.write(unicode(h.hidden_field('cdvotacao',value=c.form_result['cdvotacao'] or '')))
        context.write(u'\n')
        # SOURCE LINE 30
        context.write(unicode(h.hidden_field('cdmostra',value=c.form_result['cdmostra'] or '')))
        context.write(u'\n')
        # SOURCE LINE 31
        context.write(unicode(h.hidden_field('flativa',value=c.form_result['flativa'] or '0')))
        context.write(u'\n')
        # SOURCE LINE 32
        context.write(unicode(h.hidden_field('candidate_list',value='')))
        context.write(u'\n<div id="list" class="inner_context">\n  <table class="tablelist" width="100%" cellpadding="0" cellmargin="0">    \n    <tbody class="ligth_gray">\n      <tr>\n        <td align="right" width="15%"><strong>Data</strong></td>\n        <td width="*">')
        # SOURCE LINE 38
        context.write(unicode(h.text_field('dtvotacao',class_='ed',size='9',value=h.str_date(c.form_result['dtvotacao']) or '')))
        context.write(u' (dd/mm/aaaa)</td>\n      </tr>\n      <tr>\n        <td align="right"><strong>Mostra</strong></td>\n        <td>')
        # SOURCE LINE 42
        context.write(unicode(h.text_field('nmmostra',class_='ed',size='50',value=h.get_propertie(c.form_result,'r_mostra.nmmostra') or '')))
        context.write(u' \n            <a href="javascript:void(0)" id="btfind_mostra">')
        # SOURCE LINE 43
        context.write(unicode(h.image_tag('edit-find.png',border=0, alt='Procurar Mostra',title='Procurar Mostra')))
        context.write(u'</a></td>\n      </tr>\n    </tbody>\n  </table>\n<table class="tablelist" width="100%" cellpadding="2px" cellmargin="0">    \n  <tbody class="ligth_gray">\n  <tr>\n    <th align="left" width="90%">Candidato</th>\n    <th width="*">&nbsp;</th>\n  </tr>\n  <tr>\n    <td align="left">')
        # SOURCE LINE 54
        context.write(unicode(h.text_field('nmcandidato',class_='ed',size='63',value='')))
        context.write(u' <a href="javascript:void(0)" id="btfind_candidato">')
        context.write(unicode(h.image_tag('edit-find.png',border=0, alt='Procurar Candidato',title='Procurar Candidato')))
        context.write(u'</a></td>\n    <td align="left"><input type="button" id="btadd_candidato" class="bt" value=" Adicionar "/></td>\n  </tr>\n  </tbody>\n</table>\n  \n<div class="pn_left"><div id="candidate_grid"></div></div>\n<div class="pn_right"><input type="button" id="btremove_candidato" class="bt" value=" Remover "/></div>\n<div style="clear: both">')
        # SOURCE LINE 62
        context.write(unicode(h.submit(value=' Salvar ',class_='ed')))
        context.write(u'</div>\n\n</div>\n')
        # SOURCE LINE 65
        context.write(unicode(h.end_form()))
        context.write(u'\n<br/>\n<div id="x-window" style="background-color: #fff; color: black; padding: 0">\n <div class="hd">VotaFAM</div>\n <div class="bd"><div id="x-grid" style="background-color: #fff; color: black; padding: 0"></div></div>\n</div>\n')
        # SOURCE LINE 71
        if c.candidate_list:
            # SOURCE LINE 72
            context.write(u'    <script type="text/javascript">Votacao.candidate_edit_data = ')
            context.write(unicode(c.candidate_list))
            context.write(u';</script>\n')
        return ''
    finally:
        context.caller_stack.pop_frame()


def render_include_local_javascript(context):
    context.caller_stack.push_frame()
    try:
        h = context.get('h', UNDEFINED)
        # SOURCE LINE 3
        context.write(u'\n  ')
        # SOURCE LINE 4
        context.write(unicode(h.javascript_include_tag('/js/ui/votacao.js','/js/yui/datatable-beta-min.js','/js/yui/datasource-beta-min.js','/js/yui/button-min.js','/js/yui/container-min.js')))
        context.write(u'\n')
        return ''
    finally:
        context.caller_stack.pop_frame()


def render_include_local_styles(context):
    context.caller_stack.push_frame()
    try:
        h = context.get('h', UNDEFINED)
        # SOURCE LINE 6
        context.write(u'\n  ')
        # SOURCE LINE 7
        context.write(unicode(h.stylesheet_link_tag('/js/yui/resources/datatable/skins/sam/datatable.css','/js/yui/resources/button/skins/sam/button.css','/js/yui/resources/container/skins/sam/container.css')))
        context.write(u'\n<style type="text/css">  \n  .pn_left {\n    float: left;\n    width: 85.5%;\n    color: black;\n  }\n  \n  .pn_right {\n    float: right;\n    width: 10.5%;\n    margin-top: 35px;\n  }\n  \n  .yui-skin-sam #yui-dt0-table a, a:active, a:visited {\n    color: black;\n  }\n</style>\n')
        return ''
    finally:
        context.caller_stack.pop_frame()


